package com.jinhongone.pattern.behavior.command;

/**
 * @author jinho
 * @className Test
 * @description 测试类
 * @date 2025/3/31 9:37
 */
public class Test {
    public static void main(String[] args) {
        Order order1 = new Order();
        order1.setDiningTable(1);
        order1.setFood("西红柿炒鸡蛋",1);
        order1.setFood("米饭",1);
        order1.setFood("可乐",1);

        Order order2 = new Order();
        order2.setDiningTable(2);
        order2.setFood("小炒肉",1);
        order2.setFood("软炸肉",1);
        order2.setFood("乾隆小炒",1);
        order2.setFood("米饭",1);

        SeniorChef seniorChef = new SeniorChef();
        Command command1 = new OrderCommand(seniorChef,order1);
        Command command2 = new OrderCommand(seniorChef,order2);

        Waiter waiter = new Waiter();
        waiter.setCommand(command1);
        waiter.setCommand(command2);

        waiter.orderUp();

    }
}
